package com.ruoyi.zhgd.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ruoyi.common.annotation.DataColumn;
import com.ruoyi.common.annotation.DataPermission;
import com.ruoyi.zhgd.domain.NLaboratoryAsphaltCombustionFurnaceRes;
import com.ruoyi.zhgd.domain.bo.NLaboratoryAsphaltCombustionFurnaceResBo;
import com.ruoyi.zhgd.domain.bo.ZjExperimentBindingBo;
import com.ruoyi.zhgd.domain.vo.NLaboratoryAsphaltCombustionFurnaceResVo;
import com.ruoyi.common.core.mapper.BaseMapperPlus;
import org.apache.ibatis.annotations.Param;

import java.util.Map;

/**
 * 燃烧法沥青含量测定仪（燃烧炉）_结果Mapper接口
 *
 * @author zyb
 * @date 2023-09-11
 */
public interface NLaboratoryAsphaltCombustionFurnaceResMapper extends BaseMapperPlus<NLaboratoryAsphaltCombustionFurnaceResMapper, NLaboratoryAsphaltCombustionFurnaceRes, NLaboratoryAsphaltCombustionFurnaceResVo> {

    /**
     * 燃烧法沥青含量测定仪（燃烧炉）_结果设备列表
     * @param build
     * @param bo
     * @return
     */
    @DataPermission({
        @DataColumn(key = "deptName",value = "p.dept_id")
    })
    Page<NLaboratoryAsphaltCombustionFurnaceResVo> page(Page<Object> build, @Param("bo") NLaboratoryAsphaltCombustionFurnaceResBo bo);

    /**
     * 查询已关联数据
     * @param build
     * @param bo
     * @return
     */
    @DataPermission({
        @DataColumn(key = "deptName",value = "dept.dept_id")
    })
    Page<Map<String, Object>> getRelPage(Page<Object> build, @Param("bo") ZjExperimentBindingBo bo);

    /**
     * 是否关联是否合格状态更新
     * @param laboratoryId
     * @param eligible
     * @param relevance
     */
    void updateStatus(@Param("laboratoryId") String laboratoryId, @Param("eligible") Integer eligible, @Param("relevance") Integer relevance);
}
